package tech.aistar.service.center;

import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Service;
import tech.aistar.entity.RealName;

/**
 * Created by 23827 on 2019/10/11.
 */
@Service
public interface IRealNameService {
    @Select("insert into real_name(user_id,sname,id_card) values(#{userId},#{sname},#{idCard})")
    void save(RealName realName);

    @Select("select * from real_name where id = #{value}")
    RealName getById(Integer id);

    //通过user_id查询所有的
    @Select("select * from real_name where user_id = #{user_id}")
    RealName findByUserId(Integer user_id);
}
